/**	
	*	
	*	Struct
	*				
	*	cac struct su dung cho du an		
	*		
	*	History:	
	*			
	*			DATE									AUTHOR						DESCRIPTION		
	*		--------------------------------------------------------------------------------------		
	*		08-Nov-2012			Tuannh							Create	new	
	*		26-Nov-2012			Tuannh							Modified	
	*
*/
/***** kieu geometry *****/
Geometries = 
{
	None: "",
	Point : "point",
	Polyline : "polyline",
	Polygon : "polygon"
};

/****** thuc hien khi thao tac cho tuyen de them moi tai san *******/

AssetAction =
{
	Init: 0,
	FirstPoint: 1, // tao diem dau
	LastPoint: 2, // tao diem cuoi
	End: 3
};

PositionPointOnPolyline =
{
	None : 0, //nam ngoai
	DiemDau : 1, // vi tri diem dau tien cua line
	DiemGiua : 2, // vi tri diem giua cua line
	DiemCuoi : 3 // vi tri diem cuoi cua line
};

// tao struct
function structData(sNames) {
    var names = sNames.split('|');
    var count = names.length;
    function constructor() {
        for (var i = 0; i < count; i++) {
            this[names[i]] = arguments[i];
        };
    }
    return constructor;
};
/*******************/

/****** cong cu thao tac ban do *****/
PortletTypeAction = {
	None : -1, // ko lam gi
	Default : 0, // pan
	ZoomIn : 1, // phong to
	ZoomOut : 2, // thu nho
	FixZoomIn : 3, // phong to theo ty le co san
	FixZoomOut : 4, // thu nho theo ty le co san
	Find : 5, // tim kiem
	Identify : 6, // xem thong tin doi tuong
	Search : 26, // tim kiem
	Print : 7, // in
	Mesaure : 8, // do khoang cach
	BackExtent : 9, // quay lai trang thai tuoc cua ban do
	NextExtent : 10, // toi trang thai sau
	Insert : 11, // them doi tuong
	InsertCoor : 32, // them doi tuong bang cach nhap toa do
	Edit : 12, // sua thong itn doi tuong
	Delete : 13, // xoa doi tuong
	Split : 14, // chia doi tuong
	Merge : 15, // hop doi tuong
	Trim : 16, // cat doi tuong
	Extent : 17, // noi doi tuong
	AddLineExtension : 18,
	AddLineExtensionAngle : 18, // them 1 line ung voi 1 goc so voi line khac
	AddLineExtensionParallel : 20, // them 1 line song song so voi line khac
	AddLineExtensionDistance : 21, // them 1 line ung voi 1 khang cach so voi line khac
	AddVertex : 22, // them dinh cho doi tuong
	Copy : 23, // copy doi tuong
	DelVertext : 24, // xoa dinh cua doi tuong
	Save : 25, // luu doi tuong
	FullExtent : 26, // full ban do ra toan man hinh
	Snap : 27, // bat dinh doi tuong
	BookMark: 28, // bookmark
	ExportImage: 29, // xuat ra anh
	SelectAll: 30, // tim tat ca cac doi tuong
	Refresh: 31 // lam tuoi ban do
};

/****** thao thac khi modify feature *******/
ActionModifyFeature = 
{	
	None : 0, // ko lam gi
	Drag : 1, // keo tha doi tuong
	Vertex : 2, // thao tac voi dinh cua doi tuong
	Delvertex : 3, // xoa dinh cua doi tuong 
	Attribute : 4, // thong tin thuoc tinh cua doi tuong
	Merge : 5, // hop doi tuong
	Extent : 6, // noi doi tuong
	Trim : 7 // cat doi tuong
};
/********************/